package com.conwax.gmap.event;

import org.apache.wicket.ajax.AjaxRequestTarget;

public abstract class MoveEndHandler implements GEventHandler {

	public String getEvent() {
		return "moveend";
	}

	public void onEvent(AjaxRequestTarget target) {
		onMoveEnd(target);
	}

	/**
	 * Override this method to provide handling of a moveend.<br>
	 * You can get the new center coordinates of the map by calling
	 * {@link GMap2#getCenter()}.
	 * 
	 * @param target
	 *            the target that initiated the move
	 */
	protected abstract void onMoveEnd(AjaxRequestTarget target);

}
